package com.ruoyi.framework.config;

import com.ruoyi.system.mapper.SysUserMapper;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * TODO
 *
 * @author Nicholas
 * @date 2021-02-19 18:10
 */

@Component
public class Boom {
    @Resource
    private StringRedisTemplate stringRedisTemplate;
    @Resource
    private SysUserMapper sysUserMapper;
    @Scheduled(cron ="0/30 * * * * ?" )
    public void boom(){
        stringRedisTemplate.opsForValue().get("dada");
        sysUserMapper.selectUserById(213123L);
    }
}
